package net.tv90.auth.model.dto;

import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.Pattern;
import lombok.Data;

@Data
public class UserLoginByUsernameDTO {

    @NotEmpty(message = "用户名不能为空")
    @Pattern(regexp = "^\\w{4,}$", message = "用户名必须大于4位，且只能包含字母、数字和下划线")
    String username;

    @NotEmpty(message = "密码不能为空")
    String password;
}
